#include<iostream>
using namespace std;
#include<string>
#include<algorithm>
class Solution {
public:
    string tran(int num) {
        string ans;
        while (num) {
            ans += num % 2 + '0';
            num /= 2;
        }
        reverse(ans.begin(), ans.end());
        return ans;
    }
    string convertDateToBinary(string date) {
        int year = (date[0] - '0') * 1000 + (date[1] - '0') * 100 + (date[2] - '0') * 10 + date[3] - '0';
        int month = (date[5] - '0') * 10 + date[6] - '0';
        int day = (date[8] - '0') * 10 + date[9] - '0';
        string ans;
        ans += tran(year);
        ans += '-';
        ans += tran(month);
        ans += '-';
        ans += tran(day);
        return ans;
    }
};